package com.jdrx.sw.sewage.remote;

import com.jdrx.platform.dubbo.common.beans.DubboRpcBean;
import com.jdrx.platform.dubbo.common.service.IDubboRpcService;
import com.jdrx.sw.sewage.beans.dto.MtLogAddDTO;
import org.apache.dubbo.config.annotation.Reference;
import org.springframework.stereotype.Service;

/**
 * 行为分析(日志)管理接口
 * @author Administrator
 *
 */
@Service
public class TenantLogRemote {
	@Reference(group = "${group.app.name.tenant-app}", check = false)
	private IDubboRpcService iDubboRpcService;
	
	public void add(MtLogAddDTO dto) throws Exception {
		DubboRpcBean rpcBean = DubboRpcBean.builder().setRpcPath("/api/tenant/log/add")
				.setBody(dto)
				.build();
		RemoteUtil.parseReturnData(iDubboRpcService.callback(rpcBean));
	}
}